package com.zzh.webhook.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.List;
import java.util.Map;

@Data
@Configuration
@ConfigurationProperties(prefix = "project")
public class ProjectConfig {
    private Git git;
    private Modules modules;
    private Docker docker;

    @Data
    public static class Git {
        private String url;
        private String localPath;
    }

    @Data
    public static class Modules {
        private List<String> commonModules;
        private List<String> allModules;
    }

    @Data
    public static class Docker {
        private Map<String, DockerModule> modules;

        @Data
        public static class DockerModule {
            private int portInternal;
            private int portExternal;
        }
    }
} 